package com.i2works.smartluolong.web.service.items.impl;

import com.i2works.smartluolong.utils.basecommon.BaseCommonServiceImpl;
import com.i2works.smartluolong.utils.exception.DAOException;
import com.i2works.smartluolong.utils.exception.ServiceException;
import com.i2works.smartluolong.web.dal.items.dao.IItemsStepsDAO;
import com.i2works.smartluolong.web.entity.items.ItemsStepsDO;
import com.i2works.smartluolong.web.entity.items.ItemsStepsQuery;
import com.i2works.smartluolong.web.service.items.IItemsStepsService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

/**
 * 事项步骤分工业务层实现类
 *
 * @author Liu Yutao <koal@vip.qq.com>
 * @date 2018/11/3 2:23
 */

@Service("itemsStepsService")
public class ItemsStepsServiceImpl extends BaseCommonServiceImpl<ItemsStepsQuery, ItemsStepsDO> implements IItemsStepsService {

    @Autowired
    private IItemsStepsDAO itemsStepsDAO;


    @Override
    public void deleteByItemId(Integer itemId) throws ServiceException {
        try {
            itemsStepsDAO.deleteByItemId(itemId);
        } catch (DAOException e) {
            throw new ServiceException(e);
        }
    }
}
